package com.chen.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.chen.entity.Question;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author personcoder007
 * @since 2022-08-16
 */
public interface QuestionMapper extends BaseMapper<Question> {

    /**
     *   ===> type  题目类型
     * @param page
     * @param params
     * @return
     */
    Page<Question> findPage(@Param("page") Page<Question> page,@Param("params") Map<String, Object> params);

    /**
     * 批量删除
     * @param ids
     */
    void delBath(@Param("ids") List<Integer> ids);

    Page<Question>  selectMutiContions(@Param("page") Page<Question> page,@Param("query") Map<String, Object> query);


    List<Map<String,Object>> selectQuestionSource();
}
